#include <iostream>
using namespace std;
 
 /**
  * 对象内存分配 
  * 代码来源： https://www.runoob.com/cplusplus/cpp-dynamic-memory.html
  * */
class Box
{
   public:
      Box() { 
         cout << "call structure ." <<endl; 
      }
      ~Box() { 
         cout << "call destructor" <<endl; 
      }
};
 
int main( )
{
   Box* myBoxArray = new Box[4];
 
   delete [] myBoxArray; // 删除数组
   return 0;
}